#!/bin/sh

intltool-prepare

cd po
INTLTOOL_EXTRACT=/usr/bin/intltool-extract intltool-update -p -g desktop-files

for fil in `ls *.po`
do
    LOCALE=${fil%%.po}
    echo "Processing $LOCALE ..."
    msguniq $fil -o $fil.tmp
    mv -f $fil.tmp $fil
    INTLTOOL_EXTRACT=/usr/bin/intltool-extract intltool-update -d -g desktop-files $LOCALE
done
cd ..

find . -name *.in -not -name POTFILES.in -print | (while read; do rm -f "${REPLY%%.in}"; done )
